﻿@{
    ViewBag.Title = "CustomerComments";
    Layout = "~/Views/Shared/_AdminLayout.cshtml";
}
<html>
    <head>
        <script type="text/javascript">
            function searchCC() {
                $('#dg').datagrid('load', {
                    SiteName: $('#txtSiteName').val(),
                    PromName: $('#txtPromName').val()
                });
            }
        </script>
    </head>
    <body>
        <table id="dg" title="Comment" class="easyui-datagrid" style="height:500px"
                url="/PromotionComment/GetAllCC"
                toolbar="#toolbar" pagination="true" iconCls="icon-ok"
                rownumbers="true" fitColumns="true" singleSelect="true">
            <thead>
                <tr>
                    <th field="PromotionCommentId" width="50" hidden="true">PromotionCommentId</th>
                    <th field="SiteName" width="50">Site Name</th>
                    <th field="PromotionName" width="50">Promotion Name</th>
                    <th field="PromotionCommentBody" width="50">Comment</th>
                    <th field="CreateDate" formatter="ToJavaScriptDate" width="50">CreateDate</th>
                </tr>
            </thead>
        </table>        
        <div id="toolbar">
            <div>
                Site Name:
                <input id="txtSiteName" style="width: 150px">
                &nbsp;&nbsp;&nbsp;&nbsp;
                Promotion Name:
                <input id="txtPromName" style="width: 150px">
                <a href="#" class="easyui-linkbutton" data-options="plain:true,iconCls:'icon-search'" onclick="searchCC()">Search</a>
            </div>
        </div>
    </body>
</html>
